<?php
/**
Exibe um formul�rio para a altera��o de uma reserva j� cadastrado no banco de dados.
*/

if(!isset($_SESSION))
{
   session_start();
}

if( !function_exists('__autoload') )
{
    function __autoload($class_name) {
    require_once $class_name . '.php';
    }
}

SAEO::ValidarAcesso( array( 0, 2 ) );


$ano = new Ano();
$anosCadastrados = $ano->CarregarAnos() # carrega do banco de dados todos os anos cadastrados e retorna o resultado em um array
?>
<html>
           <head>
           <title>SAEO - Buscar Empenho</title>
           <script type='text/javascript' src='templates/programa.js'></script>
           <script type='text/javascript' src='templates/campus.js'></script>
           <script type='text/javascript' src='templates/setor.js'></script>
           <script type='text/javascript' src='templates/reserva.js'></script>
           <script type='text/javascript' src='templates/empenho.js'></script>
           <script type='text/javascript' src='templates/hintbox.js'></script>
           <script type='text/javascript' src='templates/js.js'></script>
           <script type='text/javascript' src='templates/ajax.js'></script>
           <script type='text/javascript' src='templates/validacoes.js'></script>
           <link rel='stylesheet' type='text/css' href='templates/estilos.css'/>

           </head>
     <body class='body' onload=''>
     <form name='buscar_empenho' id='buscar_empenho' action='ListarEmpenho.php' method='get' onsubmit=''>
     <table width='779' border='0' cellspacing='0' cellpadding='0' align='center' bgcolor='#FFFFFF'>
            <input type="hidden" name="operacao" value="<?php echo $_GET['operacao'];?>" />
            <tr>
                <td colspan='2'><?php include "Topo.php"; ?></td>
            </tr>
            <tr>
                <td colspan='2'><div class='titulosTabelas' style='width:779; height:20; background:url(templates/tabela.jpg)'>BUSCA DE EMPENHO</div></td>
            </tr>
            <tr>
                <td colspan='2'>&nbsp;</td>
            </tr>
            <tr>
                <td colspan='2'><table class='tabela' width='650' border='0' cellspacing='0' cellpadding='0' align='center' bgcolor='#FFFFFF'>
                           <tr>
                               <td colspan='2'>&nbsp;</td>
                           </tr>
                           <tr>
                               <td class='textoTabelas' width='30%'>&nbsp;Pesquisar Por:</td>
                               <td class='textoTabelas'>
                                   <select name='opcao' id='opcao' class='inputTexto'  onchange='ProcessarOpcoesDeBusca( this.value,"buscaEmpenho" );' >
                                           <option value='0'>Selecione o filtro</option>
                                           <option value='processo'>Processo</option>
                                           <option value='numEmpenho'>Nota Empenho</option>
                                           <option value='unidade'>Unidade</option>                                           
                                   </select>                                   
                               </td>
                           </tr>
                           <tr>
                               <td colspan='2'>&nbsp;</td>
                           </tr>
                           <tr>
                               <td colspan='2'>
                                   <div id='informacaoBuscaReserva''>                                  
                                    <table class='tabela' width='650' style='border-style: none' border='0' cellspacing='0' cellpadding='0' align='center' bgcolor='#FFFFFF'>
                                    	<tbody id="tbCampoBuscaEmpenho">
                                        </tbody>                                        
                                          <tr>
                                              <td colspan='2'>&nbsp;</td>
                                          </tr>
                                         	
                                   </table>
                               </div>
                               </td>                           
                          </tr>
                           <tr>
                               <td colspan='2'>&nbsp;</td>
                           </tr>
                            <tr>
                               <td colspan='2'>
                                   <div id='informacaoFonte' style='display:none;'>                                                                 
                                    <table class='tabela' width='650' style='border-style: none' border='0' cellspacing='0' cellpadding='0' align='center' bgcolor='#FFFFFF'>
                                    	<tbody id="tbCampoFonte">
                                        </tbody>                                        
                                          <tr>
                                              <td colspan='2'>&nbsp;</td>
                                          </tr>
                                          <tr>
                                              <td colspan='2' height='46'><input type='image' style='width:100px;height:30px;position:relative;left:540px' src='templates/btavancar.JPG'/></td>
                                          </tr>
                                   </table>
                               </div>
                               </td>
                           </tr>
                     </table>
                </td>
            </tr>
            <tr>
                <td colspan='2'>&nbsp;</td>
            </tr>
            <tfoot>
                   <tr>
                   		<td><?php include 'rodapeCreditos.php'; ?></td>
                   </tr>
            </tfoot>
     </table>
     </form>
     </body>
     </html>
